package cn.liontalk.web;

import cn.liontalk.service.HystrixRibbonService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author ZhouZhe
 * @version 1.0
 * @description
 * @date 2019-03-31 20:18
 **/
@RestController
@RequestMapping(value = "/hystrix/ribbon")
public class HystrixRibbonController {

    @Autowired
    private HystrixRibbonService hystrixRibbonService;

    @RequestMapping(value = "/demo")
    public String hystrixDemo(@RequestParam("name") String name){
        return hystrixRibbonService.testHystrixRibbon(name);
    }

}
